<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>通过 JavaScript 访问 HTML 元素</title>
</head>
<body>

<p id="Demo">This is paragraph 1.</p>
<p id="demo">This is paragraph 2.</p>

<script>
  document.getElementById("demo").innerHTML = "HELLO.";
</script>

</body>
</html>